import { createSlice } from '@reduxjs/toolkit'

const initialState = {
  value: 0,
  start:"北京",
  end:"三亚",
  date:"2025-03-19"
}

export const citylist = createSlice({
  name: 'counter',
  initialState,
  reducers: {
    setStart(state,action){
        state.start = action.payload
    },
    setEnd(state,action){
        state.end = action.payload
    },
    setDate(state,action){
        state.date = action.payload
    },
  },
})

// Action creators are generated for each case reducer function
export const {setDate,setEnd,setStart  } = citylist.actions

// export default counterSlice.reducer